/*
 ============================================================================
 Name		: RocketAppUi.cpp
 Author	  : Leo.Shi
 Copyright   : Your copyright notice
 Description : CRocketAppUi implementation
 ============================================================================
 */

// INCLUDE FILES
#include <avkon.hrh>
#include <aknmessagequerydialog.h>
#include <aknnotewrappers.h>
#include <stringloader.h>
#include <f32file.h>
#include <s32file.h>
#include <hlplch.h>

#include <Rocket_0xE19182F8.rsg>


#include "Rocket.hrh"
#include "Rocket.pan"
#include "RocketApplication.h"
#include "RocketAppUi.h"
#include "RocketAppView.h"

_LIT( KFileName, "C:\\private\\E19182F8\\Rocket.txt" );
_LIT( KText, "Rocket");

// ============================ MEMBER FUNCTIONS ===============================


// -----------------------------------------------------------------------------
// CRocketAppUi::ConstructL()
// Symbian 2nd phase constructor can leave.
// -----------------------------------------------------------------------------
//
void CRocketAppUi::ConstructL()
	{
	// Initialise app UI with standard value.
	BaseConstructL(CAknAppUi::EAknEnableSkin);

	this->StatusPane()->MakeVisible(EFalse);
	// Create view object
	this->iap = 1;
	iAppView = CRocketAppView::NewL(ClientRect());
	this->AddToStackL(iAppView);
	
	
	}
// -----------------------------------------------------------------------------
// CRocketAppUi::CRocketAppUi()
// C++ default constructor can NOT contain any code, that might leave.
// -----------------------------------------------------------------------------
//
CRocketAppUi::CRocketAppUi()
	{
	// No implementation required
	}

// -----------------------------------------------------------------------------
// CRocketAppUi::~CRocketAppUi()
// Destructor.
// -----------------------------------------------------------------------------
//
CRocketAppUi::~CRocketAppUi()
	{
	if (iAppView)
		{
		this->RemoveFromStack(iAppView);
		delete iAppView;
		iAppView = NULL;
		}

	}

// -----------------------------------------------------------------------------
// CRocketAppUi::HandleCommandL()
// Takes care of command handling.
// -----------------------------------------------------------------------------
//
void CRocketAppUi::HandleCommandL(TInt aCommand)
	{
	switch (aCommand)
		{
		case EEikCmdExit:
		case EAknSoftkeyExit:
			Exit();
			break;

	
		default:
			
			break;
		}
	}

// End of File
